#!/bin/bash

set -e

mkdir -p build
cd build || exit 1
cmake ..
make
ctest -V

if [ -n "$CI" ]; then
  if [[ "$(uname -s)" == "Linux" ]] ; then
    make memcheck
  fi
fi
